/*
	@file: log/source/logger/OStreamLogger.cpp
	@author: Wolfhead
 */
#include "logger/OStreamLogger.h"
#include <iostream>
#include <boost/foreach.hpp>

namespace logger
{

int OStreamLogger::log(const std::string& message)
{
	boost::lock_guard<boost::mutex> lock(m_mutex);
	std::cout << message << std::endl;
	return 0;
}

int OStreamLogger::log(const std::vector<std::string>& message_vec)
{
	boost::lock_guard<boost::mutex> lock(m_mutex);
	BOOST_FOREACH(const std::string& message, message_vec)
	{
		std::cout << message << std::endl;
	}
	return 0;
}


}//namespace logger

